
import 'package:meePet/utils/ScreenUtils.dart';

extension DoudleExt on double {
  h() {
    return ScreenUtils.instance.setHeight(this);
  }

  w() {
    return ScreenUtils.instance.setWidth(this);
  }

  ///最小宽适配法
  double sw(){
    return ScreenUtils.instance.setWidth(this);
  }

  double sp() {
    return ScreenUtils.instance.setSp(this);
  }
}

extension IntExt on int {
  h() {
    return ScreenUtils.instance.setHeight(this.toDouble());
  }

  w() {
    return ScreenUtils.instance.setWidth(this.toDouble());
  }

  ///最小宽适配法
  double sw(){
    return ScreenUtils.instance.setWidth(this.toDouble());
  }

  double sp() {
    return ScreenUtils.instance.setSp(this.toDouble());
  }
}
